<template>
	<u-cell-group>
		<u-cell-item :arrow="false" title="门店名称" :value="data && data.Name"></u-cell-item>
		<u-cell-item :arrow="false" title="门店代码" :value="data && data.Account"></u-cell-item>
		<u-cell-item :arrow="false" title="门店简称" :value="data && data.Referred"></u-cell-item>
		<u-cell-item :arrow="false" title="门店负责人姓名" :value="data && data.NickName"></u-cell-item>
		<u-cell-item :arrow="false" title="门店负责人手机号" :value="data && data.Mobile"></u-cell-item>

		<block v-if="loadCity">
			<u-cell-item :border-bottom="!showDeliveryAddress" :arrow="false" title="门店地址" @click="showAddressSelect = true">
				<city-select :disabled="true" :value="[data.ProvinceId, data.CityId, data.DistrictId]"></city-select>
				<u-input :disabled="true" :customStyle="{ color: '#909399', fontSize: '26rpx' }" :value="data.Address" inputAlign="right" placeholder="详细地址"></u-input>
			</u-cell-item>
			<u-cell-item v-if="showDeliveryAddress" :border-bottom="false" :arrow="false" title="收货地址" @click="showAddressSelect = true">
				<city-select :disabled="true" :value="[data.Delivery_ProvinceId, data.Delivery_CityId, data.Delivery_DistrictId]"></city-select>
				<u-input :disabled="true" :customStyle="{ color: '#909399', fontSize: '26rpx' }" :value="data.Delivery_Address" inputAlign="right" placeholder="详细地址"></u-input>
			</u-cell-item>
		</block>
	</u-cell-group>
</template>

<script>
export default {
	name: 'store-information',
	props: {
		showDeliveryAddress: {
			type: Boolean,
			default: false
		},
		loadCity: {
			type: Boolean,
			default: true
		},
		data: {
			type: Object,
			default() {
				return {
					Name: '',
					// 简称
					Referred: '',
					// 门店负责人姓名
					NickName: '',
					// 门店负责人手机号
					Mobile: '',
					// 门店地址
					ProvinceId: null,
					CityId: null,
					DistrictId: null,
					// 门店详细地址
					Address: null,

					Delivery_ProvinceId: null,
					Delivery_DistrictId: null,
					Delivery_CityId: null,
					Delivery_Address: null
				};
			}
		}
	},
	data() {
		return {
			showAddressSelect: false,
			areaCode: []
		};
	},
	methods: {}
};
</script>

<style lang="scss"></style>
